#ifndef __UART_H__
#define __UART_H__

#include "stm32f10x.h"
#include "drv_common.h"

enum uart_num {UART_NUM1 = 0, UART_NUM2, UART_NUM3, UART_NUM4, UART_NUM5};

extern void insert_uart_data_buf(struct data_buf *node, enum uart_num port);
extern int remove_uart_data_buf(struct data_buf *node, enum uart_num port);

extern void uart1_init(unsigned int baudrate);
extern void uart2_init(unsigned int baudrate);

extern void uart_send(USART_TypeDef *port, unsigned char *data, unsigned int len);

#endif /* __UART_H__ */
